gtk4.git
10 years agoAdwaita: Don't grow flat entries
Matthias Clasen [Fri, 12 Feb 2016 03:35:11 +0000 (22:35 -0500)]
Adwaita: Don't grow flat entries

Entries in treeviews and similar embedded situations don't really
work well if their height is forced to be big. Take out the min-height
for these.

https://bugzilla.gnome.org/show_bug.cgi?id=761686

10 years agocannot not -> must
Caolán McNamara [Tue, 26 Jan 2016 12:08:01 +0000 (12:08 +0000)]
cannot not -> must

https://bugzilla.gnome.org/show_bug.cgi?id=761826

10 years agoplacesview: Fix some minor issues
Matthias Clasen [Fri, 12 Feb 2016 03:15:43 +0000 (22:15 -0500)]
placesview: Fix some minor issues

Make the button not grow too big, and ensure that the actionbar
has a background.

https://bugzilla.gnome.org/show_bug.cgi?id=761792

10 years agoAdwaita: tone down treeview separators
Matthias Clasen [Fri, 12 Feb 2016 03:03:47 +0000 (22:03 -0500)]
Adwaita: tone down treeview separators

10 years agoFix Quartz clipboard image retrieval.
John Ralls [Thu, 11 Feb 2016 21:49:07 +0000 (13:49 -0800)]
Fix Quartz clipboard image retrieval.

It does no good to iterate through a series of mime types to call a
function when the eventually-called function,
_gtk_quartz_get_selection_data_from_pasteboard() in this case, gives the
wrong answer and stops the iteration on all but one especially if that
one isn't first.

The one is "image/tiff" and the quartz pasteboard function will return
any image type Quartz knows about for it, so lose the iteration and use
only "image/tiff".

10 years agoAdwaita: fix bogus selector...
Lapo Calamandrei [Thu, 11 Feb 2016 17:38:31 +0000 (18:38 +0100)]
Adwaita: fix bogus selector...

...ruining the indeterminate check animation

10 years agoAdwaita: animate check and radios
Lapo Calamandrei [Thu, 11 Feb 2016 17:27:25 +0000 (18:27 +0100)]
Adwaita: animate check and radios

10 years agomir: Add C++ guards
Emmanuele Bassi [Thu, 11 Feb 2016 11:59:12 +0000 (11:59 +0000)]
mir: Add C++ guards

Avoid missing symbols when compiling C++ including the GDK Mir backend
header.

https://bugzilla.gnome.org/show_bug.cgi?id=761829

10 years agonotebook: fix arrow states
Matthias Clasen [Thu, 11 Feb 2016 11:47:28 +0000 (06:47 -0500)]
notebook: fix arrow states

Some code was confusing 0 with ARROW_NONE, causing us to not properly
update the state of the arrow gadgets.

10 years agoinspector: Don't use unused variables
Benjamin Otte [Thu, 11 Feb 2016 03:14:56 +0000 (04:14 +0100)]
inspector: Don't use unused variables

Windows-specific refactorings broke this.

10 years agowin32: Move init code into windows-specific code
Benjamin Otte [Thu, 11 Feb 2016 03:14:28 +0000 (04:14 +0100)]
win32: Move init code into windows-specific code

Avoids warnings about undefined functions on non-windows.

10 years agowin32 theme: Add a GtkWin32Theme object
Benjamin Otte [Mon, 8 Feb 2016 03:07:40 +0000 (04:07 +0100)]
win32 theme: Add a GtkWin32Theme object

This object wraps a HTHEME and takes care of recreating it on theme changes.

10 years agowin32: Capture WM_THEMECHANGED
Benjamin Otte [Mon, 8 Feb 2016 01:49:34 +0000 (02:49 +0100)]
win32: Capture WM_THEMECHANGED

We're not doing anything useful with it yet. This will follow in the coming commits.

10 years agowin32: Remove XP-specific code
Benjamin Otte [Mon, 8 Feb 2016 01:26:26 +0000 (02:26 +0100)]
win32: Remove XP-specific code

We don't support XP anymore.

10 years agowin32: Remove unused functions / header includes
Benjamin Otte [Mon, 8 Feb 2016 01:26:07 +0000 (02:26 +0100)]
win32: Remove unused functions / header includes

10 years agowin32: Always pass a window to the default event filters
Benjamin Otte [Sun, 7 Feb 2016 22:48:46 +0000 (23:48 +0100)]
win32: Always pass a window to the default event filters

This has to happen or the event filter cannot identify what type
of display the event is from (ie if it's an XEvent, a broadway
event or a win32 MSG.

10 years agotestsuite: No warnings on type conversions please
Benjamin Otte [Sun, 7 Feb 2016 19:14:02 +0000 (20:14 +0100)]
testsuite: No warnings on type conversions please

long is 32bit on win64, so it's int cast to pointer of different size, and gcc doesn't like that.

10 years agofilechoosernativewin32: Remove unused variables
Benjamin Otte [Sun, 7 Feb 2016 18:20:09 +0000 (19:20 +0100)]
filechoosernativewin32: Remove unused variables

10 years agoimcontextsimple: Remove unused variable on win32
Benjamin Otte [Sun, 7 Feb 2016 18:19:36 +0000 (19:19 +0100)]
imcontextsimple: Remove unused variable on win32

10 years agotestgtk: Compile without warnings on win32
Benjamin Otte [Sun, 7 Feb 2016 18:18:18 +0000 (19:18 +0100)]
testgtk: Compile without warnings on win32

10 years agotests: Remove unused variable
Benjamin Otte [Sun, 7 Feb 2016 18:18:00 +0000 (19:18 +0100)]
tests: Remove unused variable

10 years agowin32 theme: Get rid of deprecated style properties
Benjamin Otte [Sun, 7 Feb 2016 03:11:55 +0000 (04:11 +0100)]
win32 theme: Get rid of deprecated style properties

That's pretty easy, because we can just delete them. The theme is broken either way.

10 years agowin32 theme: Replace pseudoclasses with undeprecated ones
Benjamin Otte [Sun, 7 Feb 2016 03:00:46 +0000 (04:00 +0100)]
win32 theme: Replace pseudoclasses with undeprecated ones

10 years agowin32 theme: Do a quick'n'dirty search/replace
Benjamin Otte [Sun, 7 Feb 2016 02:54:17 +0000 (03:54 +0100)]
win32 theme: Do a quick'n'dirty search/replace

Try to replace the old style names with then new style names.

The theme is still entirely way too broken. But at least one can see something.

10 years agowin32: Remove _gdk_display usge from dnd code
Benjamin Otte [Sat, 6 Feb 2016 05:35:41 +0000 (06:35 +0100)]
win32: Remove _gdk_display usge from dnd code

10 years agowin32: Make cursor code work without _gdk_display
Benjamin Otte [Sat, 6 Feb 2016 04:53:51 +0000 (05:53 +0100)]
win32: Make cursor code work without _gdk_display

10 years agowin32: Stop using _gdk_display global in device code
Benjamin Otte [Sat, 6 Feb 2016 04:46:09 +0000 (05:46 +0100)]
win32: Stop using _gdk_display global in device code

Use gdk_device_get_display() instead.

10 years agowin32embedwidget: Mark deprecated sections
Benjamin Otte [Sat, 6 Feb 2016 04:23:32 +0000 (05:23 +0100)]
win32embedwidget: Mark deprecated sections

10 years agofilechoosernativewin32: Silence gcc
Benjamin Otte [Sat, 6 Feb 2016 03:33:50 +0000 (04:33 +0100)]
filechoosernativewin32: Silence gcc

10 years agofilechoosernativewin32: Add missing return type
Benjamin Otte [Sat, 6 Feb 2016 03:33:14 +0000 (04:33 +0100)]
filechoosernativewin32: Add missing return type

Looks like a line accidentally was deleted there.

10 years agofilechoosernativewin32: Define MSC_VER at top of file
Benjamin Otte [Sat, 6 Feb 2016 03:24:39 +0000 (04:24 +0100)]
filechoosernativewin32: Define MSC_VER at top of file

The headers we include might include windows headers which define _MSC_VER already.

10 years agoprintoperation-win32: Silence gcc
Benjamin Otte [Sat, 6 Feb 2016 03:24:23 +0000 (04:24 +0100)]
printoperation-win32: Silence gcc

10 years agomountoperation: Silence gcc
Benjamin Otte [Sat, 6 Feb 2016 02:58:39 +0000 (03:58 +0100)]
mountoperation: Silence gcc

Also, printf()ing a GPid should be forbidden.

10 years agoimmodule: Stop gcc from complaining
Benjamin Otte [Sat, 6 Feb 2016 02:38:37 +0000 (03:38 +0100)]
immodule: Stop gcc from complaining

10 years agowin32: Remove deprecation warnings in dnd code
Benjamin Otte [Sat, 6 Feb 2016 01:18:54 +0000 (02:18 +0100)]
win32: Remove deprecation warnings in dnd code

10 years agowin32: Remove deprecation warnings in devicemanager code
Benjamin Otte [Sat, 6 Feb 2016 01:18:28 +0000 (02:18 +0100)]
win32: Remove deprecation warnings in devicemanager code

10 years agowin32: Use g_set_object()
Benjamin Otte [Sat, 6 Feb 2016 01:17:43 +0000 (02:17 +0100)]
win32: Use g_set_object()

... instead of a hand-rolled version that does the same thing.

10 years agowin32: Fix empty body warning
Benjamin Otte [Sat, 6 Feb 2016 01:14:37 +0000 (02:14 +0100)]
win32: Fix empty body warning

10 years agogtk-demo: Add more foreign drawing examples
Matthias Clasen [Thu, 11 Feb 2016 02:20:34 +0000 (21:20 -0500)]
gtk-demo: Add more foreign drawing examples

Add a notebook with an active tab.
Based on a patch by Caolan McNamara.

10 years agogtk-demo: attempt at a notebook with active box-shadow in tab
Caolán McNamara [Wed, 10 Feb 2016 21:01:54 +0000 (21:01 +0000)]
gtk-demo: attempt at a notebook with active box-shadow in tab

10 years agotestgtk: Remove an unused variable
Matthias Clasen [Wed, 10 Feb 2016 21:10:23 +0000 (16:10 -0500)]
testgtk: Remove an unused variable

10 years agogtk-demo: Add a menu to foreigndrawing
Caolán McNamara [Wed, 10 Feb 2016 13:39:24 +0000 (13:39 +0000)]
gtk-demo: Add a menu to foreigndrawing

and demo that the block arrows require GTK_STATE_FLAG_DIR_LTR or
GTK_STATE_FLAG_DIR_RTL set to appear

https://bugzilla.gnome.org/show_bug.cgi?id=761828

10 years agoUpdated Brazilian Portuguese translation
Rafael Fontenelle [Wed, 10 Feb 2016 16:55:55 +0000 (16:55 +0000)]
Updated Brazilian Portuguese translation

10 years agooverlay: set css name
Timm Bäder [Wed, 10 Feb 2016 13:03:56 +0000 (14:03 +0100)]
overlay: set css name

10 years agoframe: Set border gadget state after creating it
Timm Bäder [Wed, 10 Feb 2016 13:03:39 +0000 (14:03 +0100)]
frame: Set border gadget state after creating it

10 years agospinbutton: Free the gadget in finalize
Timm Bäder [Wed, 10 Feb 2016 11:30:35 +0000 (12:30 +0100)]
spinbutton: Free the gadget in finalize

10 years agocss node tree: Fix crash
Timm Bäder [Wed, 10 Feb 2016 11:28:32 +0000 (12:28 +0100)]
css node tree: Fix crash

This function would return "" whenever the state of the css node was
unset, causing a crash when selecting the css node tree from the
sidebar.

10 years agogtk-demo: Improve the tag implementation
Matthias Clasen [Wed, 10 Feb 2016 05:07:37 +0000 (00:07 -0500)]
gtk-demo: Improve the tag implementation

Add margins and make it so that clicking on margins next to
links does not activate them.

10 years agotext view: Improve tag pointer tracking
Matthias Clasen [Wed, 10 Feb 2016 05:01:54 +0000 (00:01 -0500)]
text view: Improve tag pointer tracking

A problem that has been observed in polari is that links in tags
are clickable all the way into the margin. This problem is caused
by gtk_text_view_get_iter_at_position ignoring the return value
of pango_layout_xy_to_index. Instead, pass it back as a boolean
return value. This is technically an API break, but we've allowed
ourselves to change return types from void to gboolean before.

10 years agogtkmagnifier: Avoid a crash if the inspected widget is finalized
Rui Matos [Tue, 9 Feb 2016 14:30:00 +0000 (15:30 +0100)]
gtkmagnifier: Avoid a crash if the inspected widget is finalized

If the inspected widget is finalized and we then try to disconnect
from its signals we'll crash.

https://bugzilla.gnome.org/show_bug.cgi?id=761775

10 years agoA few more documentation fixes
Timm Bäder [Tue, 9 Feb 2016 07:05:16 +0000 (08:05 +0100)]
A few more documentation fixes

10 years agoVarious documentation fixes
Timm Bäder [Mon, 8 Feb 2016 21:49:01 +0000 (22:49 +0100)]
Various documentation fixes

Always have Since: annotations at the very bottom, use the correct
ClassName::signal-name/ClassName:property-name syntax, fix a few typos
in type names, wrong function names, non-existing type names, etc.

10 years agogtk: Fix some return-values annotations (transfer none/full)
Rico Tzschichholz [Mon, 8 Feb 2016 13:02:25 +0000 (14:02 +0100)]
gtk: Fix some return-values annotations (transfer none/full)

10 years agowin32: properly handle show and focus
Ignacio Casal Quinteiro [Mon, 8 Feb 2016 12:20:02 +0000 (13:20 +0100)]
win32: properly handle show and focus

The first time a window is shown we should always call SW_SHOWNORMAL.
Understand whether to call SW_SHOW or SW_SHOWNORMAL and the specific
ones for the temporary windows depending on IsWindowVisible.
This also fixes the problem when calling gtk_window_present and
the window is snapped to the left or right of the screen.

This patch is based on the patches provided by Yevgen Muntyan
and Aleksander Morgado.

https://bugzilla.gnome.org/show_bug.cgi?id=698652

10 years agowin32: on focus restore the window if iconified
Yevgen Muntyan [Mon, 8 Feb 2016 08:24:12 +0000 (09:24 +0100)]
win32: on focus restore the window if iconified

If the window is iconified we want to restore the window
to get the proper size instead of showing it normal which
would change the size of the window.

https://bugzilla.gnome.org/show_bug.cgi?id=698652

10 years agoUpdated Kazakh translation
Baurzhan Muftakhidinov [Mon, 8 Feb 2016 08:54:59 +0000 (08:54 +0000)]
Updated Kazakh translation

10 years agoinspector: Avoid crash in magnifier
Matthias Clasen [Mon, 8 Feb 2016 08:34:24 +0000 (09:34 +0100)]
inspector: Avoid crash in magnifier

We can't use gtk_widget_draw on widgets that are not allocated.

10 years agoAdd css node tests for box packing
Matthias Clasen [Mon, 8 Feb 2016 08:15:39 +0000 (09:15 +0100)]
Add css node tests for box packing

More tests to ensure that CSS node order is always physical
left-to-right.

10 years agoimage: _get_style_context never returns NULL
Timm Bäder [Sun, 7 Feb 2016 07:29:49 +0000 (08:29 +0100)]
image: _get_style_context never returns NULL

10 years agoMake gtk_icon_helper_invalidate private
Timm Bäder [Sat, 6 Feb 2016 17:51:48 +0000 (18:51 +0100)]
Make gtk_icon_helper_invalidate private

10 years agoAdd and use gtk_icon_helper_invalidate_for_change
Timm Bäder [Sat, 6 Feb 2016 08:24:36 +0000 (09:24 +0100)]
Add and use gtk_icon_helper_invalidate_for_change

10 years agoiconhelper: Save whether the surface is symbolic
Timm Bäder [Sat, 6 Feb 2016 08:23:11 +0000 (09:23 +0100)]
iconhelper: Save whether the surface is symbolic

10 years agostylepropertyimpl: Use GTK_CSS_AFFECTS_SYMBOLIC_ICON
Timm Bäder [Fri, 5 Feb 2016 08:28:11 +0000 (09:28 +0100)]
stylepropertyimpl: Use GTK_CSS_AFFECTS_SYMBOLIC_ICON

Things like color affect symbolic icons, but not colored icons, while
other css properties like -gtk-icon-effect affect colored icons, but not
symbolic ones.

10 years agocsstypes: Add GTK_CSS_AFFECTS_SYMBOLIC_ICON
Timm Bäder [Fri, 5 Feb 2016 08:27:37 +0000 (09:27 +0100)]
csstypes: Add GTK_CSS_AFFECTS_SYMBOLIC_ICON

10 years agocssstylechange: Add helper function to print change
Timm Bäder [Fri, 5 Feb 2016 09:28:13 +0000 (10:28 +0100)]
cssstylechange: Add helper function to print change

So I don't have to print both styles to the console, paste them both
into a file and then run diff on the 2 files anymore.

10 years agoiconhelper: Un-duplicate some code
Timm Bäder [Sat, 6 Feb 2016 08:27:00 +0000 (09:27 +0100)]
iconhelper: Un-duplicate some code

10 years agoRemove more unnecessary redraws
Timm Bäder [Fri, 5 Feb 2016 09:00:46 +0000 (10:00 +0100)]
Remove more unnecessary redraws

The call to gtk_widget_set_state_flags immediately before these already
queues a redraw/allocate/resize in case they have to be queued.

10 years agoAdwaita: No rounded corners for fullscreen
Matthias Clasen [Sun, 7 Feb 2016 17:00:29 +0000 (18:00 +0100)]
Adwaita: No rounded corners for fullscreen

If the theme has rounded corners for fullscreen, we don't tell the
window manager that we are now fully opaque, which then makes things
less efficient than they should be.

https://bugzilla.gnome.org//show_bug.cgi?id=761571

10 years agobox gadget: Fix allocation without baseline
Matthias Clasen [Sun, 7 Feb 2016 14:08:56 +0000 (15:08 +0100)]
box gadget: Fix allocation without baseline

When we don't get a baseline passed in, we want to basically
center the children inside the allocation. There was an attempt
in the code to do 'internal baseline alignment', but it had the
side effect of moving the contents to the top when we don't get
a baseline passed in. Remove it for now, this needs some more
infrastructure to do properly.

https://bugzilla.gnome.org/show_bug.cgi?id=761363

10 years agowidget-factory: Update levelbar example
Matthias Clasen [Sun, 7 Feb 2016 14:00:58 +0000 (15:00 +0100)]
widget-factory: Update levelbar example

Set reasonable level offsets.

10 years agoUpdated Spanish translation
Daniel Mustieles [Sun, 7 Feb 2016 12:18:58 +0000 (13:18 +0100)]
Updated Spanish translation

10 years agoUpdated Spanish translation
Daniel Mustieles [Sun, 7 Feb 2016 12:18:49 +0000 (13:18 +0100)]
Updated Spanish translation

10 years agoFix levelbar css node tests
Matthias Clasen [Sun, 7 Feb 2016 10:37:30 +0000 (11:37 +0100)]
Fix levelbar css node tests

These were affected by the recent change to level offset handling.
At the same time, make the test files more realistic by updating
the level offsets when we set a custom range.

10 years agolevel bar: Document buildable syntax
Matthias Clasen [Sun, 7 Feb 2016 10:28:08 +0000 (11:28 +0100)]
level bar: Document buildable syntax

10 years agoUpdated Polish translation
Piotr Drąg [Sat, 6 Feb 2016 18:32:03 +0000 (19:32 +0100)]
Updated Polish translation

10 years agolevel bar: Fix offset behavior
Matthias Clasen [Sat, 6 Feb 2016 15:42:25 +0000 (16:42 +0100)]
level bar: Fix offset behavior

We had some odd special-casing for the lowest and highest offset
that did not quite work. The new rule is simple: If the value
is between offset n-1 and n, it gets the style for offset n.

https://bugzilla.gnome.org/show_bug.cgi?id=761416

10 years agolevel bar: Improve documentation
Matthias Clasen [Sat, 6 Feb 2016 15:19:13 +0000 (16:19 +0100)]
level bar: Improve documentation

The docs were not explaining at all what happens to existing
level offsets when the min- or max-value of a level bar are
changed.

10 years agolevel bar: Make the full offset official
Matthias Clasen [Sat, 6 Feb 2016 15:11:17 +0000 (16:11 +0100)]
level bar: Make the full offset official

We are adding 3 offsets, not just two. Add a define for the
third one, and mention it in the docs.

10 years agoUpdated Slovak translation
Dušan Kazik [Sat, 6 Feb 2016 14:16:02 +0000 (14:16 +0000)]
Updated Slovak translation

10 years agowayland: rework buffer management code (3 changes)
Ray Strode [Sat, 6 Feb 2016 13:03:27 +0000 (08:03 -0500)]
wayland: rework buffer management code (3 changes)

There are a couple of issues with the way that buffers are handled in
wayland in right.  These issues mean that:

 - buffers can get leaked at a fairly fast clip under the right
   conditions. This leads to the OOM killer kicking in and
   gnome-shell and gnome-terminal (for instance) showing memory
   usage in the high gigabytes range.

 - drawing can happen to a shared memory buffer at the same time
   the compositor is reading out the pixels.  This can lead to
   glitching in drawing and other undefined behavior by the compositor.

This changeset reworks how buffer management is done in the code to try
to address both problems.

The first change (commit 2c300081) addresses the leak by dropping code
that has an unchecked cairo_surface_reference call.  The code is dropped
rather than fixed, because it has a more serious issue: it's overarching
purpose is to deal with shared memory buffer contention with the
compositor, but it does it in a racy way and so fails at that mission.

The second change (commit 40e91195a) moves what layer of the code buffer
release events are handled. This is an organizational change in the
code, with no functional changes, but it's important for the last change
in the changeset.

The last change (commit c80dd549) adds back code for dealing with shared
member buffer contention in a race free way. The new code is careful to
never reuse a buffer that hasn't been explicitly released by the
compositor.

10 years agowayland: stage uncommitted changes to dedicated buffer
Ray Strode [Fri, 29 Jan 2016 16:19:03 +0000 (11:19 -0500)]
wayland: stage uncommitted changes to dedicated buffer

Right now we use one buffer for both staged changes (freshly painted
changes waiting for the frame clock to send to the compositor) and
committed changes (changes actively being read by the compositor
process). This creates a problem in the event we need to stage updates
at the same time the compositor is processing committed updates: we
can't change what the compositor is actively processing.

The current solution for handling this contention is to allocate a
temporary buffer on the spot at the time the updates are staged, and to
copy that buffer back to the shared buffer later.  The problem, though,
is that the copy to the shared buffer currently happens as soon as
the updates are finished being staged, not when the shared buffer is
done being processed by the compositor.

In order to address that problem, this commit changes the code to always
stage changes to a dedicated staging buffer.  The staging buffer is
used exclusively by the client until the client is done with it, and then
once that staging buffer is committed, the client never writes to that
buffer again.  If the client needs to stage new updates, it allocates a
brand new staging buffer, draws to it, and back fills the undrawn parts
of the buffer from a copy of the contents of the committed buffer.

As an optimization, the compositor has the option of releasing the
committed buffer back to the client.  If it does so before the client
needs to stage new updates, then the client will reuse the buffer
for staging future updates.  This optimization prevents having to allocate
a new staging buffer and the associated cost of back filling
that new buffer with a readback of the committed buffer.

https://bugzilla.gnome.org/show_bug.cgi?id=761312

10 years agowayland: don't handle buffer release centrally
Ray Strode [Tue, 2 Feb 2016 19:36:25 +0000 (14:36 -0500)]
wayland: don't handle buffer release centrally

Right now we handle buffer releases coming from the
compositor in a central place. We add a listener when
first creating the shared buffers.

This is problematic because a buffer can only have
one listener on it at once so users of the buffer
can't get notified when it's released.

This commit moves the buffer listener code from the
centrally managed display code to the cursor and window
code.

https://bugzilla.gnome.org/show_bug.cgi?id=761312

10 years agowayland: always return FALSE from begin_paint
Ray Strode [Tue, 2 Feb 2016 17:20:22 +0000 (12:20 -0500)]
wayland: always return FALSE from begin_paint

The client and compositor share access to the window
pixel buffers. After the client hands off (commits)
the buffer to the compositor it's not supposed to write
to it again until it's released by the compositor.

The code tries to deal with this contention by allocating
a temporary buffer and using that in the mean time. This
temporary buffer is allocated by a higher layer of the code
when begin_paint returns TRUE. Unfortunately, that layer of
the code has no idea when the buffer is released, so it ends
up blitting the temporary buffer back to the shared buffer
prematurely.

This commit changes begin_paint to always return FALSE.

A future commit will address the contention problem in
a different way.

https://bugzilla.gnome.org/show_bug.cgi?id=761312

10 years agowayland: use g_clear_pointer when destroying cairo surfaces
Ray Strode [Wed, 3 Feb 2016 01:43:12 +0000 (20:43 -0500)]
wayland: use g_clear_pointer when destroying cairo surfaces

There are a few places where we destroy a cairo surface and
then nullify it. This commit changes those to use
g_clear_pointer instead.

It also drops a cairo_surface_finish call that is unnecessary

https://bugzilla.gnome.org/show_bug.cgi?id=761312

10 years agowayland: rename cairo surface user data key to be more specific
Ray Strode [Wed, 3 Feb 2016 15:12:23 +0000 (10:12 -0500)]
wayland: rename cairo surface user data key to be more specific

This commit renames the key name to be more specific for clarity.

https://bugzilla.gnome.org/show_bug.cgi?id=761312

10 years agowayland: move server proxy objects to substructure
Ray Strode [Tue, 2 Feb 2016 16:42:52 +0000 (11:42 -0500)]
wayland: move server proxy objects to substructure

This commit moves the server proxy objects to a substructure
for clarity.

https://bugzilla.gnome.org/show_bug.cgi?id=761312

10 years agowayland: rename window->surface to window->wl_surface
Ray Strode [Tue, 2 Feb 2016 16:27:54 +0000 (11:27 -0500)]
wayland: rename window->surface to window->wl_surface

The name surface is really overloaded when dealing
with wayland windows.

To alleviate ambiguity, this commit changes the name
of the "surface" and "subsurface" members to have
a wl_ prefix.

https://bugzilla.gnome.org/show_bug.cgi?id=761312

10 years agoFix stylecontext tests
Matthias Clasen [Sat, 6 Feb 2016 08:58:46 +0000 (09:58 +0100)]
Fix stylecontext tests

This was broken by f7ec9c98ef0ef8740c93f96af9d971b0211118c1,
since type names are no longer used at all in CSS matching.

10 years agoUpdate CSS docs regarding type names
Matthias Clasen [Sat, 6 Feb 2016 08:28:51 +0000 (09:28 +0100)]
Update CSS docs regarding type names

We no longer use type names at all.

10 years agocssselector: Remove type references
Benjamin Otte [Fri, 5 Feb 2016 22:47:48 +0000 (23:47 +0100)]
cssselector: Remove type references

We don't use types anymore.

10 years agocssmatcher: Remove type argument from name matcher
Benjamin Otte [Fri, 5 Feb 2016 22:43:05 +0000 (23:43 +0100)]
cssmatcher: Remove type argument from name matcher

We no longer use types when matching names.

10 years agoinspector: Drop type name from node list
Benjamin Otte [Fri, 5 Feb 2016 18:31:03 +0000 (19:31 +0100)]
inspector: Drop type name from node list

It's not used anymore in the CSS, so people don't need to see it.

10 years agocssimageradial: Only allow at "<position>" after other props
Benjamin Otte [Fri, 5 Feb 2016 18:01:48 +0000 (19:01 +0100)]
cssimageradial: Only allow at "<position>" after other props

Don't allow syntax like
  at top left circle
but follow the spec about requiring the at <position> right before the
comma.

This is porbably because
  circle at 10px 10px
could be interpreted as
  circle 10px at 10px
with the now disallowed syntax, too.

Test included.

10 years agocssimageradial: Only emit one error for wrong position
Benjamin Otte [Fri, 5 Feb 2016 17:30:28 +0000 (18:30 +0100)]
cssimageradial: Only emit one error for wrong position

Test included.

10 years agocss tests: Fix style tests
Matthias Clasen [Fri, 5 Feb 2016 14:54:50 +0000 (15:54 +0100)]
css tests: Fix style tests

Commit d0fd7990c3f2c738f86185418ccd76b14da8a776 changed
the location of builtin themes, breaking the loading of
the empty theme in test-css-style.

10 years agocss tests: Fix expected output
Matthias Clasen [Fri, 5 Feb 2016 14:50:35 +0000 (15:50 +0100)]
css tests: Fix expected output

This is fallout from f7ec9c98ef0ef8740c93f96af9d971b0211118c1.

10 years agocss: Convert numbers with GTK's dpi
Benjamin Otte [Fri, 5 Feb 2016 13:50:37 +0000 (14:50 +0100)]
css: Convert numbers with GTK's dpi

Don't hardcode 96 for dpi, but instead use the value of the -gtk-dpi
property (that mirrors the GdkScreen's dpi if it wasn't set explicitly).

This makes these values scale when the large font setting in
control-center is enabled.

10 years agocss: Properly convert em, ex and rem to pixels
Benjamin Otte [Fri, 5 Feb 2016 13:42:41 +0000 (14:42 +0100)]
css: Properly convert em, ex and rem to pixels

The previous code converted to pt.

10 years agoAdwaita: darker background for popovers
Lapo Calamandrei [Fri, 5 Feb 2016 13:10:36 +0000 (14:10 +0100)]
Adwaita: darker background for popovers

10 years agolevelbar: Make discrete levelbars behave as before
Matthias Clasen [Fri, 5 Feb 2016 10:53:50 +0000 (11:53 +0100)]
levelbar: Make discrete levelbars behave as before

During the gadget conversion, the drawing of discrete levelbars
was unintentionally changed to draw a wide trough but narrow
blocks, which does not look great. So go back to the previous
way of drawing things.

https://bugzilla.gnome.org/show_bug.cgi?id=761428